Conventional stream data processors perform a predetermined process on a single data stream in a specific format and then output. For example, a transport stream in ISO/IEC 13818-1 (MPEG2 system) is widely known as a format of data streams. For the transport stream, a plurality of program data and other secondary information are formed into packets, and the packets are respectively given packet IDs for identifying them and form one stream. In a transport stream packet, the position and length of a bit in which a packet ID is present are fixed. Also, a packet ID is uniquely determined in a single transport stream, while duplication of packet IDs can occur in packets included in a plurality of transport streams.
A conventional stream data processor is shown in FIG. 10.
The conventional stream data processor comprises a stream input portion 1001, a packet filter 1002, a packet data processing portion 1003, and a stream output portion 1004.
The stream input portion 1001 detects a packet header from continuous bit strings in an input stream and outputs packet data.
The packet filter 1002 determines as a packet ID a bit string at a specific position in the input packet data and compares it with a designated bit string. When they match, this packet is output.
The packet data processing portion 1003 performs a predetermined process on the packet data.
The stream output portion 1004 outputs the processed packet data in a predetermined format.
The conventional stream data processor addresses only a specific format for the identification of a packet and performs a specific process for the format. In addition, it does not address simultaneous processes of a plurality of streams.
Next, a stream data processor, in which the function of the conventional stream data processor is extended so that two types of streams can be processed, is shown in FIG. 11.
In FIG. 11, the format of an input stream is analyzed in a packet analysis portion 1005, and according to the format, which process result of two packet filters 1002, which are provided so that two different types of formats can be addressed, is selected in a packet selector 1006. Similarly, which process result of two packet data processing portions 1003, which are provided so that two different types of formats can be addressed, is selected in a packet selector 1006.
FIG. 12 is a stream data processor, which is extended by locating two of the stream data processors in FIG. 11 in parallel so that two data streams each having a different type of format can be processed simultaneously.
However, when a plurality of data stream processors are formed by locating a plurality of conventional packet filters and conventional stream data processors in parallel as in FIGS. 11 and 12, the size of the device increases in proportion to the number of data streams processed, leading to an increased cost.
In this way, using conventional technique, when a data stream having a further different format is processed, or when the number of data streams processed simultaneously is increased, the size of the device further increases.
Because the identification of packets in streams having a plurality of different formats is performed, a packet filter for each format is needed. In addition, if a plurality of conventional stream data processors are provided in parallel to process a plurality of data streams simultaneously, the size of the device increases in proportion to the number of data streams processed simultaneously.
In addition, when a packet filter is provided for each format of streams, the operation of packet filters except for one corresponding to an input stream is unnecessary. For data processing portions, similarly, data processing portions except for one performing a necessary process for the packet data need not be operated. In this way, many portions that need not be operated simultaneously are present in the device, leading to much waste in the structure of the device.